import logging,yagmail
def log_conn():
    logging.basicConfig(filename="weidudiansanglog.txt",
                        filemode="w",
                        level=logging.DEBUG,
                        format="%(lineno)d-%(message)s-%(asctime)s-%(levelname)s")

def send_mail(filename):
    mail=yagmail.SMTP(user="3177622011@qq.com",password="tmafvuztgjqvdgeb",host="smtp.qq.com")
    mail.send(to="3177622011@qq.com",subject="维度电商系统接口测试报告",contents="报告",attachments=filename)
